package com.pig4cloud.pigx.shop.api.feign;

import com.pig4cloud.pigx.common.core.constant.SecurityConstants;
import com.pig4cloud.pigx.common.core.constant.ServiceNameConstants;
import com.pig4cloud.pigx.common.core.util.R;
import com.pig4cloud.pigx.shop.api.dto.GoodsMaterialDTO;
import com.pig4cloud.pigx.shop.api.entity.GoodsServer;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;

import java.util.List;

@FeignClient(contextId = "remoteGoodsServerService", value = ServiceNameConstants.SHOP_SERVICE)
public interface RemoteGoodsServerService {

	/**
	 * 根据Id列表获取保障服务
	 * @param ids
	 * @param from
	 * @return
	 */
	@PostMapping("/config/server/getListByIds")
	R<List<GoodsServer>> getListByIds(@RequestBody List<Long> ids, @RequestHeader(SecurityConstants.FROM) String from);

}
